<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>线性渐变</title>
</head>
<body>

<style>
    div{
        width: 800px;
        height: 200px;
        background: linear-gradient(to left,red,yellow);
        /*background: radial-gradient(circle ,red, yellow, green);*/
    }
</style>
<div>

</div>
</body>
</html>